home *** CD-ROM | disk | FTP | other *** search
/ Skunkware 5 / Skunkware 5.iso / src / Games / net3d-0.08 / README < prev    next >
Text File  |  1995-06-22  |  14KB  |  387 lines

  1. net3d - a networked, multiplayer 3d combat game
  2.  
  3. Copyright (C) 1994 by Jamie Cameron
  4. thanatos@yoyo.cc.monash.edu.au
  5. jcam2@ccds.cc.monash.edu.au
  6.  
  7.  
  8. This is version 0.08 of net3d, a simple multiplayer game written for
  9. Unix and X11. At the moment, I have only successfully tested net3d on
  10. the following systems -
  11.  
  12.     Ultrix 4.4 / 4.3    (DECstation)
  13.     OSF/1            (DEC Alpha)
  14.     HP-UX
  15.     SunOS
  16.     Solaris            (Sun Sparc Classic)
  17.     Irix 5.2        (SGI)
  18.  
  19. If you are using either of the above, then it should work. As for
  20. anything else... if you get it to compile and run then tell me about it,
  21. and any changes / bug fixes needed to get it up and running.
  22.  
  23.  
  24. COMPILING NET3D
  25.  
  26. Net3d now uses an Imakefile, so it should be possible to compile by running:
  27.  
  28.     xmkmf
  29.  
  30. followed by:
  31.  
  32.     make
  33.  
  34. If nothing goes wrong, two executables will be produced, net3d and net3dserv.
  35. net3dserv is the server for multiplayer games, and net3d the client
  36. run by each player. If you have any problems compiling, mail me and tell
  37. me what kind of system you are using, what the error was and (hopefully :)
  38. how to fix it, so I can include the fix in the next version.
  39.  
  40. There are several compile-time options that can be changed in config.h,
  41. that may have to be adjusted to get net3d to compile on your system.
  42.  
  43. The important ones are:
  44. CPPPATH        - the full path and filename for the C pre-processor on
  45.           your system. Should be found automatically by Imake
  46. USEINLINES    - determines if inline functions are used (only with gcc).
  47.           Some versions of gcc don't seem to work with them
  48.           properly.
  49.  
  50. Note - if you plan on modifying the code, then it will be necessary to run:
  51.  
  52.     makedepend *.c
  53.  
  54. to add include file dependencies to the makefile.
  55.  
  56.  
  57. RUNNING NET3D
  58.  
  59. net3d can by played in each single or multiplayer modes. To start a
  60. single player game, just type :
  61.  
  62.     net3d <vehicle files> ...
  63.  
  64. For example, if you type  net3d map2.v heli.v  then you will be flying
  65. a helicopter around a simple 3d map. Controls for the vehicle you are
  66. piloting will be displayed before the game starts, and are by default
  67. something like :
  68.  
  69. rotate left              - left    rotate right             - right
  70. accellerate              - up      decellerate              - down
  71. climb                    - a       dive                     - z
  72. halt                     - s
  73. gun left                 - o       gun right                - p
  74. gun up                   - j       gun down                 - i
  75. fire                     - return  lock on                  - l
  76. eject                    - j
  77. quit                     - q
  78. wireframe toggle         - w       build menu toggle        - b
  79.  
  80. long range view              - 1  view from stationary point   - 2
  81. view from behind vehicle     - 3  inside view                  - 4
  82. above view                   - 5  turret view                  - 6
  83. short range view             - 7  missile view                 - 8
  84. interesting thing view       - 9
  85.  
  86. Not all controls will be appropriate for all vehicles. For example, a
  87. vehicle like a tank (in tank.v) cannot fly, so the climb and dive keys
  88. have no effect. Similarly, in a vehicle with no separate gun turret,
  89. the keys for contolling the turret won't do anything.
  90.  
  91. Using the controls, you can fly or drive a vehicle around the game
  92. world. Most objects in the game, including the hills, will cause damage
  93. if your vehicle hits them. Also, other computer controlled vehicles may
  94. open fire on you or accidentally collide with you.
  95.  
  96. Locking on
  97. ----------
  98. When in viewing mode 4 or 6, the lock key (usually 'l') will lock on to
  99. the closest vehicle in your gunsights. A short description of the
  100. vehicle you have locked onto is displayed, and if your vehicle is armed
  101. with missiles, then any missiles fired will home in on the target you
  102. have chosen. 
  103.  
  104. Leaving your vehicle
  105. --------------------
  106. At any time you can eject from the vehicle you are driving, if it is a
  107. tank, helicopter or other similar piloted machine. Once you have
  108. ejected, you will be controlling a small fish (until I can create
  109. something better). Outside your vehicle you are extremely vulnerable,
  110. however you can board any unoccupied vehicle and collect trees for later
  111. use in building things. Leaving a helicopter or other flying machine at
  112. a high altitude is not recommended.
  113.  
  114. Building things
  115. ---------------
  116. The 'menu' key brings up a row of buttons along the bottom of the
  117. screen, for building various types of walls. If you have enough
  118. resources, then clicking the mouse button on one of the icons will
  119. construct the item chosen in front of your current vehicle. In addition
  120. to walls on various angles, it is also possible to build mines (which
  121. explode when hit) and autocannons (which fire at the nearest target, apart
  122. from the vehicle that created them). Resources for building can only be
  123. obtained by collecting trees, as described above.
  124.  
  125. Head-up displays
  126. ----------------
  127. When in view-mode 4 (pilot view) or 6 (gun view), the following are
  128. displayed on screen :
  129.     lock information    (top left)
  130.     radar             (top right)
  131.     hit points        (below radar)
  132.     ammunition        (below hit points)
  133.     resources        (below ammo)
  134.     velocity        (bottom left)
  135.     altitude        (top right)
  136.  
  137.  
  138. VEHICLE FILES
  139.  
  140. Several vehicle files are provided with net3d, some of which define
  141. vehicles for players to drive and some which define worlds with scenery
  142. to fly/drive around. There are also files that combine a map and a
  143. number of vehicles, for easily starting a multi-player battle.
  144.  
  145. The scenery files are:
  146.     map.v        - A complex, mountainous world with several
  147.               buildings and roads, as well as a few strange
  148.               creatures inhabiting it. Good for multi-player
  149.               games on fast machines.
  150.     map2.v        - A simple map, suitable for machines with less
  151.               processing power to throw around. 
  152.     map3.v        - A coastal area, with a few buildings and flying
  153.               creatures. Good for air combat.
  154.  
  155. The battle files are:
  156.     battle.v    - Fought on map.v, between a helicopter, two
  157.               tanks and a cosmosphere. Includes an initially
  158.               unmanned helicopter on a helipad in the top
  159.               right corner of the map.
  160.  
  161.     battle2.v    - Fought on map2.v, between a tank and two helicopters.
  162.               Good for a simple multi-player game.
  163.  
  164.     battle3.v    - Fought on map3.v, between 3 helicopters and a
  165.               speedboat. Also includes a large battleship
  166.               with 2 cannons a short distance out to sea.
  167.     space.v        - A space battle between 3 starfighters. At the
  168.               moment there isn't much scenery in this one,
  169.               though this will change when I create a few
  170.               more suitable vehicles.
  171.  
  172. The vehicle files are:
  173.     amigaball.v    -
  174.     amigaball.def.v    - A bouncing red and white amiga beachball. Useful
  175.               for scenery, but not much else.
  176.  
  177.     eye.v        -
  178.     eye.def.v    - A flying eyeball with a tail and wings. Armed
  179.               with a light tracer weapon firing from it's
  180.               tail.
  181.  
  182.     heli.v        -
  183.     heli.def.v    - A small helicopter with gun turret, firing homing
  184.               missiles.
  185.  
  186.     tank.v        -
  187.     tank.def.v    - A small tank with gun turret and reasonably
  188.               heavy armour, and armed with a cannon.
  189.  
  190.     boat.def.v    - A small speedboat with a roof mounted gun
  191.  
  192.     fish.def.v    - A large, flying fish. Used in map.v as scenery,
  193.               where it chases small birds around.
  194.  
  195.     house.def.v    - Scenery object, used in all the map files.
  196.  
  197.     cannon.def.v    - A large gun installation, used for scenery in 
  198.               map3.v
  199.  
  200.     glassfish.v    -
  201.     glassfish.def.v    - Like fish.def.v, but made of transparent polygons
  202.  
  203.     m2.v        -
  204.     m2.def.v    - A lightly armed armoured personell carrier. Has
  205.               a turret mounted machinegun.
  206.  
  207.     cosmosphere.def.v - A huge, flying cosmosphere, inspired by the
  208.                 lunatic rantings of McElwaine. :)
  209.  
  210.     gunship.v    -
  211.     gunship.def.v    - A more heavily armed helicopter, but without a
  212.               gun turret.
  213.  
  214.     ptero.v        -
  215.     ptero.def.v    - A flying pterodactyl-like bird. Used as scenery
  216.               in map.v and map3.v
  217.  
  218.     asteroid.def.v    - A slowly spinning chunk of rock, used as scenery
  219.               in space.v
  220.  
  221.     stingship.v
  222.     stingship.def.v    - A small spacegoing fighter, armed with a plama
  223.               ball cannon.
  224.  
  225. Note that vehicle files can be grouped into two types, definitions
  226. (ending with .def.v) and usable vehicles (ending with .v). Typically,
  227. the vehicle is fully defined and described in the .def.v file, with is
  228. included in the .v file, and instantiated. All the .def.v files are used
  229. in the various map and battle files to create vehicles or creatures
  230. living in that particular world.
  231.  
  232. In addition to the .v files that can be used as command line arguments,
  233. there is one additional file, extras.v, that is used by net3d. extras.v
  234. is contains the definitions of all the bullets, walls, missiles, fireballs
  235. and commonly used miscellaneous objects used in the game. However, extras.v 
  236. is not read in by net3d at run time, and thus simply modifying it will
  237. not change the appearance of objects in the game. Instead, the file is
  238. converted to a .c file during compilation and linked into the final executable
  239. program. This means that after changing extras.v, you must re-compile net3d
  240. for the changes to take effect. 
  241.  
  242.  
  243. STARTING A MULTI-PLAYER GAME
  244.  
  245. 1) Choose a machine that you want to be the game server, and on it
  246.    run :
  247.     net3dserv <vehicle file> ...
  248.    For example, to start a simple game, you might run
  249.     net3dserv battle.v
  250.  
  251. 2) Each person who wants to join the game should run :
  252.     net3d <server> <name>
  253.   on their machine, where <server> is the address of the machine the
  254.   server was run on, and <name> is the name this player wants to use
  255.   in the game. If <name> is omitted, then net3d uses your current
  256.   login name.
  257.   For example, to connect to a server on the machine foo.cc, using
  258.   the name Joe Smeg in the game, type :
  259.     net3d foo.cc Joe Smeg
  260.  
  261. 3) The server will receive connections from players and display info
  262.    about each new player on the screen. When return is hit, the server
  263.    sends information about the game world and vehicles to each player,
  264.    assigns vehicles to players and starts the game. If there are not
  265.    enough vehicles for players, then vehicles are assigned on a 'first-
  266.    come, first-served' basis.
  267.  
  268. 4) Once the game begins, the players can fight it out until only one
  269.    only remains, who will be informed of victory by a message in their
  270.    window. Once that final player hits the 'quit' key, the server and
  271.    all the clients will exit.
  272.    
  273.  
  274. COMPATABILITY PROBLEMS
  275.  
  276. This version of net3d will almost certainly fail on anything other than
  277. a 8-bit pseudocolour display, as it's the only kind of display I've got
  278. access to. Hopefully, the next version will include support for 24-bit
  279. displays, as well as grey-scale.
  280. All the networking code in net3d makes use of tcp/ip sockets, so if your
  281. version of unix doesn't support sockets then the multi-player version
  282. won't work. Hopefully single player mode will, though.
  283. Net3d also needs cpp to pre-process it's vehicle files, and looks for it
  284. in /lib/cpp by default. If you don't have cpp, then you're out of luck.
  285. If you do, but it's not in /lib, then change CPPPATH in config.h, and
  286. re-compile.
  287.  
  288.  
  289. HISTORY
  290.  
  291. version 0.01
  292.     - net3d is first let loose on the net
  293.  
  294. version 0.02
  295.     - fixed bugs and hp-ux compatability problems suggested by
  296.       R.K.Lloyd@csc.liv.ac.uk, such as division by zero if a vehicle
  297.       has max velocity zero, and core dumps when no vehicles are
  298.       given.
  299.  
  300. version 0.03
  301.     - sphere polygons are now drawn correctly
  302.     - fireballs stored in the extra vehicle file
  303.     - the server displays the name of the machine each player connects from
  304.     - clients don't kill the whole game when killed by ctrl-c
  305.     - HP-UX compatability (hopefully :)
  306.     - Sun compatability   (even more hopefully)
  307.     - the 'single' variable renamed to 'single_player'
  308.     - strerror() kludged up for suns which are missing this function
  309.  
  310. version 0.04
  311.     - improved depthsorting algorithm
  312.     - "ground none" option in map files
  313.     - "stars" option in map files
  314.     - Linux compatability (maybe?)
  315.     - new .v files and weapons
  316.     - fixed problem with dropping keystrokes
  317.  
  318. version 0.05
  319.     - added 'scale' statement for vehicles in .v files
  320.     - added a workaround for problems with mmult under linux
  321.     - improved space.v a bit
  322.  
  323. version 0.06
  324.     - minor release to fix bugs and warning messages
  325.  
  326. version 0.07
  327.     - minor bug fixes
  328.  
  329. version 0.08
  330.     - fixed core dumps under linux (at last)
  331.     - added weapon and ammuntion prizes
  332.     - fixed Solaris compile-time bugs
  333.     - fixed a few other minor niggles
  334.     - changes the way movement works internally
  335.     - started on support for brains
  336.     - added version number checking between clients and server
  337.  
  338. TODO
  339.  
  340. * make depth sort order settable in .v file
  341. * support greyscale and 24-bit graphics
  342. * creator info for maps
  343. * add missions and some kind of points system
  344. * add various interesting things to collect
  345. * make movement vector-based
  346. * create some Star Trek vehicles
  347. * optimise the 3-d graphics routines (perhaps using shared memory)
  348. * net3d home page?
  349. * use lex / yacc for parsing the vehicle file
  350. * clean up the source code :-)
  351. * add texture mapped polygons 
  352. * allow players to send one another messages
  353. * improve the intelligence of computer-controlled vehicles
  354. * anything else anyone suggests to me...
  355.  
  356.  
  357. BUGS
  358.  
  359. * Matrix multiplication dumps core under linux
  360. * Problems with depthsorting causing some polygons to dissapear / reappear
  361. * Computer controlled vehicles are stupid
  362.  
  363.  
  364. CONTRIBUTORS
  365.  
  366.  - acb                (the cosmosphere, pterodactyl, fish, chicken
  367.                  and bouncing ball vehicles)
  368.  - warthog              (the m2 tank)
  369.  - gothic            (useful suggestions for the 3d algorithms)
  370.  - R.K.Lloyd@csc.liv.ac.uk    (HPUX combatability, bug fixes, Imakefile)
  371.  - lendl@cosy.sbg.ac.at         (Sun & Linux compatability, bug fixes)
  372.  - humpy            (Linux compatability)
  373.  - germond@ensta.fr        (Bug reports and suggestions)
  374.  - jucoons@ursula.uoregon.edu    (Bug reports)
  375.  - jaggy@purplet.demon.co.uk    (Bug fixes for linux)
  376.  - ma_lwk@stu.ust.hk        (Bug reports and help with Solaris)
  377.  
  378.  
  379. LEGAL STUFF
  380.  
  381. Net3d is freely distributable and modifyable, on the condition that no
  382. fee is charged for it's distribution (except for the cost of a disc or
  383. other media). In other words, you can't sell net3d for profit.
  384. Net3d comes with no warranty, so if something goes horribly wrong with
  385. the program, causing your computer to explode... tough :).
  386.  
  387.